package com.ovopark.firecar.okhttp;

import com.caoustc.okhttplib.okhttp.BaseHttpRequestCallback;
import com.caoustc.okhttplib.okhttp.OkHttpRequestParams;

/**
 * Created by zxb on 2017/7/26.
 */

public interface HttpRequestLoader {

    /**
     * 普通post请求
     *
     * @param url      接口路径
     * @param params   参数
     * @param callback 回调函数
     */
    void postFormParseRequest(String url, OkHttpRequestParams params, BaseHttpRequestCallback callback);

    void postFormParseRequest(String url, OkHttpRequestParams params, int timeout, BaseHttpRequestCallback callback);

    void postFormParseRequest(boolean isCancel, String url, OkHttpRequestParams params, BaseHttpRequestCallback callback);

    void postFormParseRequest(boolean isCancel, String url, OkHttpRequestParams params, int timeout, BaseHttpRequestCallback callback);

    void postFormParseRequest(String url, OkHttpRequestParams params, Class dataClass, BaseHttpRequestCallback callback);

    void postFormParseRequest(String url, OkHttpRequestParams params, int timeout, Class dataClass, BaseHttpRequestCallback callback);

    void postFormParseRequest(boolean isCancel, String url, OkHttpRequestParams params, Class dataClass, BaseHttpRequestCallback callback);

    void postFormParseRequest(boolean isCancel, String url, OkHttpRequestParams params, int timeout, Class dataClass, BaseHttpRequestCallback callback);

    void getFormParseRequest(String url, OkHttpRequestParams params, Class dataClass, BaseHttpRequestCallback callback);

    void getFormParseRequest(String url, OkHttpRequestParams params, BaseHttpRequestCallback callback);

    void putFormParseRequest(String url, OkHttpRequestParams params, Class dataClass, BaseHttpRequestCallback callback);
}
